package com.scm.error;

public class SCPException extends Exception{
	
	private static final long serialVersionUID = 1L;
	private String userMessage;
    private int errorCode;
    private String errorDescription;

    public SCPException(String message) {

       super(message);
    }

    public SCPException(String userMessage, int errorCode, String errorDescription) {
        this.userMessage = userMessage;
        this.errorCode = errorCode;
        this.errorDescription = errorDescription;
    }
    public SCPException(String message,String userMessage, int errorCode, String errorDescription) {
         super(message);
        this.userMessage = userMessage;
        this.errorCode = errorCode;
        this.errorDescription = errorDescription;
    }

    public int getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(int errorCode) {
        this.errorCode = errorCode;
    }



    public String getErrorDescription() {
        return errorDescription;
    }

    public void setErrorDescription(String errorDescription) {
        this.errorDescription = errorDescription;
    }

    public String getUserMessage() {
        return userMessage;
    }

    public void setUserMessage(String userMessage) {
        this.userMessage = userMessage;
    }

    @Override

    public String toString() {
        return super.toString()+"" +
                " userMessage: "+getUserMessage()+"" +
                " errorCode: "+getErrorCode()+"" +
                " errorDescription: "+getErrorDescription();
    }
}
